<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>
<body>
    <script src="./js/vue.js"></script>
    <div id="app">
        <h3>单选</h3>
        <select v-model="fruit">
            <option disabled value="">请选择您想吃的水果</option>
            <option>苹果</option>
            <option>香蕉</option>
            <option>橘子</option>
        </select>
        <p>您想吃的水果是：{{fruit}}</p>
        
        <!--multiple属性是开启多选 列表单选时绑定的是选项值，多选时，v-model绑定的是一个数组-->
        <h3>多选</h3>
        <select v-model="fruits" multiple>
            <option>请选择您想吃的水果</option>
            <option>苹果</option>
            <option>香蕉</option>
            <option>橘子</option>
        </select>
        <p>您想吃的水果是：{{fruits}}</p>
    </div>
    <script>
        let vm = new Vue({
             el: '#app',
             data:{
                fruit:'',
                fruits:[]
             }
         })
    </script>
</body>
</html>